Many applications and operating system components are programmed to use operating system identification information to make certain run-time decisions. These operating system identifiers are commonly referred to as Stock Keeping Units (SKUs). By identifying the operating system at run-time, rather than when the applications are compiled, the applications or operating system components are able to exist as a single binary for use on a variety of operating systems. Being able to make these decisions at run-time makes it possible to have a single binary that works seamlessly across different operating system SKUs. When the application or operating system component is selected for execution, a query is made for the SKU of the underlying operating system. Based on the returned SKU, aspects of the application or operating system component may be enabled or disabled in accordance with the capabilities of the operating system identified by the SKU. Typical operating system information identified by the SKUs includes the operating system version, operating system build number, service pack number, or any other information typically associated with operating systems.
Generally, the SKU information is requested by making a call to an application programming interface (“API”) or other software program that then returns the SKU corresponding to the current executing operating system. However, APIs using this method create several problems. First, adding SKUs corresponding to new or improved operating systems to these APIs can create application compatibility issues. Often the calling applications have expected or supported SKUs hard coded into the application binaries. Accordingly, if the application is installed on an operating system that was unknown at the time the application was created, the application will abort because the returned SKU will not match any of the SKUs hard coded into the application. Given that the newer operating system may have been specifically designed to remain compatible with previous versions, unnecessary compatibility issues are created.
Second, because current applications rely on the returned SKU information to execute correctly, dropping the use of SKU information is not possible without breaking these legacy applications.